import request from '../uniHttp';

// 上传文件,支持多文件上传
export const upload = async (data?: object|any) => {
  return await request('/upload/upload', 'post', data);
}

// 获取所有文件信息
export const getFileList = async (data?: object|any) => {
  return await request('/upload/getFileList', 'post', data);
}

// 获取单个文件信息
export const getFile = async (id?: string|number) => {
  return await request('/upload/getFile', 'get', id);
}

// 删除文件
export const deleteFile = async (id?: string|number) => {
  return await request('/upload/deleteFile', 'delete', id);
}
